<style lang="scss" scoped>
    @import '../../css/training.scss';
    .el-table-box{padding-left: 60px;}
</style>

<template>
    <section>

        <section class="breadcrumb-box clearfix">
            <el-breadcrumb separator=" > " class="fl">
                <el-breadcrumb-item >培训</el-breadcrumb-item>
                <el-breadcrumb-item :to="{path: '/training/training-manage'}">培训管理</el-breadcrumb-item>
                <el-breadcrumb-item v-if="$route.meta">{{$route.meta.title}}</el-breadcrumb-item>
            </el-breadcrumb>
        </section>

        <section class="sign-result-box mt">

            <p class="fs-16 srb-total-num">报名人数: {{Total}}</p>
            <section class="el-table-box">
                <el-table :data="signData"  >
                    <el-table-column label="学员名字" width="150" prop="Username"></el-table-column>
                    <el-table-column label="所属部门" width="150" prop="DepartmentName"></el-table-column>
                    <el-table-column label="报名时间" prop="EnrollTime"></el-table-column>
                </el-table>
            </section>

        </section>

    </section>
</template>

<script>

	import qs from 'qs'

	export default{
		data: function(){
			return {
				TrainID:'',
				Total:'',
				signData: [],
            }
		},
		mixins: [mixinMethods],
		methods: {
            getSignResultList(){
                this.TrainID = this.$route.query.id;
				axios.post('/com/train/getEnrollMembers', qs.stringify({
					TrainID : this.TrainID,
                })).then( (res) => {
                    var d = res.data;
                    if(d.flag == 1){
                    	this.Total = d.data.Total;
                    	this.signData = d.data.Rows;
                    }else{
						this.$message.error(d.msg);
					}
                } );
            }

		},
		mounted: function(){
			this.getSignResultList();
		}
	}


</script>